<template>
  <div class="app-container">
    <el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
      <el-form-item label="共几页" prop="totalPage">
        <el-input
          v-model="queryParams.totalPage"
          placeholder="请输入共几页"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="第几页" prop="page">
        <el-input
          v-model="queryParams.page"
          placeholder="请输入第几页"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="报告编号" prop="baogbh">
        <el-input
          v-model="queryParams.baogbh"
          placeholder="请输入报告编号"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="检测单位名称" prop="jiancdwmc">
        <el-input
          v-model="queryParams.jiancdwmc"
          placeholder="请输入检测单位名称"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="工程部位/用途" prop="gongcbwyt">
        <el-input
          v-model="queryParams.gongcbwyt"
          placeholder="请输入工程部位/用途"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="样品名称" prop="yangpmc">
        <el-input
          v-model="queryParams.yangpmc"
          placeholder="请输入样品名称"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="样品编号" prop="yangpbh">
        <el-input
          v-model="queryParams.yangpbh"
          placeholder="请输入样品编号"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="样品数量" prop="yangpsl">
        <el-input
          v-model="queryParams.yangpsl"
          placeholder="请输入样品数量"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="样品状态" prop="yangpzt">
        <el-input
          v-model="queryParams.yangpzt"
          placeholder="请输入样品状态"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="样品时间" prop="yangpsj">
        <el-input
          v-model="queryParams.yangpsj"
          placeholder="请输入样品时间"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="检测日期" prop="jiancrq">
        <el-input
          v-model="queryParams.jiancrq"
          placeholder="请输入检测日期"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="试验条件温度" prop="shiytjwd">
        <el-input
          v-model="queryParams.shiytjwd"
          placeholder="请输入试验条件温度"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="试验条件湿度" prop="shiytjsd">
        <el-input
          v-model="queryParams.shiytjsd"
          placeholder="请输入试验条件湿度"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="检测依据" prop="jiancyj">
        <el-input
          v-model="queryParams.jiancyj"
          placeholder="请输入检测依据"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="判定依据" prop="pandyj">
        <el-input
          v-model="queryParams.pandyj"
          placeholder="请输入判定依据"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="主要仪器设备名称及编号" prop="zhuyyqsbmcjbh">
        <el-input
          v-model="queryParams.zhuyyqsbmcjbh"
          placeholder="请输入主要仪器设备名称及编号"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="取样位置" prop="quywz">
        <el-input
          v-model="queryParams.quywz"
          placeholder="请输入取样位置"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="委托/任务编号" prop="weitrwbh">
        <el-input
          v-model="queryParams.weitrwbh"
          placeholder="请输入委托/任务编号"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="土样产地" prop="tuycd">
        <el-input
          v-model="queryParams.tuycd"
          placeholder="请输入土样产地"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="代表数量" prop="daibsl">
        <el-input
          v-model="queryParams.daibsl"
          placeholder="请输入代表数量"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="附加声明" prop="fujsm">
        <el-input
          v-model="queryParams.fujsm"
          placeholder="请输入附加声明"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="检测结论" prop="jiancjl">
        <el-input
          v-model="queryParams.jiancjl"
          placeholder="请输入检测结论"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="施工委托单位" prop="shigwtdw">
        <el-input
          v-model="queryParams.shigwtdw"
          placeholder="请输入施工委托单位"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="工程名称" prop="gongcmc">
        <el-input
          v-model="queryParams.gongcmc"
          placeholder="请输入工程名称"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="设备id逗号分隔" prop="shebIds">
        <el-input
          v-model="queryParams.shebIds"
          placeholder="请输入设备id逗号分隔"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="标识该表是报告" prop="bgFlag">
        <el-input
          v-model="queryParams.bgFlag"
          placeholder="请输入标识该表是报告"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="检测依据ids" prop="jiancyjIds">
        <el-input
          v-model="queryParams.jiancyjIds"
          placeholder="请输入检测依据ids"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="判定依据ids" prop="pandyjIds">
        <el-input
          v-model="queryParams.pandyjIds"
          placeholder="请输入判定依据ids"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称1" prop="kuanglmc1">
        <el-input
          v-model="queryParams.kuanglmc1"
          placeholder="请输入矿料名称1"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称2" prop="kuanglmc2">
        <el-input
          v-model="queryParams.kuanglmc2"
          placeholder="请输入矿料名称2"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称3" prop="kuanglmc3">
        <el-input
          v-model="queryParams.kuanglmc3"
          placeholder="请输入矿料名称3"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称4" prop="kuanglmc4">
        <el-input
          v-model="queryParams.kuanglmc4"
          placeholder="请输入矿料名称4"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称5" prop="kuanglmc5">
        <el-input
          v-model="queryParams.kuanglmc5"
          placeholder="请输入矿料名称5"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称6" prop="kuanglmc6">
        <el-input
          v-model="queryParams.kuanglmc6"
          placeholder="请输入矿料名称6"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称7" prop="kuanglmc7">
        <el-input
          v-model="queryParams.kuanglmc7"
          placeholder="请输入矿料名称7"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料名称8" prop="kuanglmc8">
        <el-input
          v-model="queryParams.kuanglmc8"
          placeholder="请输入矿料名称8"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例1" prop="kuanglbl1">
        <el-input
          v-model="queryParams.kuanglbl1"
          placeholder="请输入矿料比例1"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例2" prop="kuanglbl2">
        <el-input
          v-model="queryParams.kuanglbl2"
          placeholder="请输入矿料比例2"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例3" prop="kuanglbl3">
        <el-input
          v-model="queryParams.kuanglbl3"
          placeholder="请输入矿料比例3"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例4" prop="kuanglbl4">
        <el-input
          v-model="queryParams.kuanglbl4"
          placeholder="请输入矿料比例4"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例5" prop="kuanglbl5">
        <el-input
          v-model="queryParams.kuanglbl5"
          placeholder="请输入矿料比例5"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例6" prop="kuanglbl6">
        <el-input
          v-model="queryParams.kuanglbl6"
          placeholder="请输入矿料比例6"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例7" prop="kuanglbl7">
        <el-input
          v-model="queryParams.kuanglbl7"
          placeholder="请输入矿料比例7"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="矿料比例8" prop="kuanglbl8">
        <el-input
          v-model="queryParams.kuanglbl8"
          placeholder="请输入矿料比例8"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="水泥剂量" prop="shuinjl">
        <el-input
          v-model="queryParams.shuinjl"
          placeholder="请输入水泥剂量"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="最佳含水率" prop="zuijhsl">
        <el-input
          v-model="queryParams.zuijhsl"
          placeholder="请输入最佳含水率"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="最大干密度" prop="zuidgmd">
        <el-input
          v-model="queryParams.zuidgmd"
          placeholder="请输入最大干密度"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item label="施工控制压实度" prop="shigkzysd">
        <el-input
          v-model="queryParams.shigkzysd"
          placeholder="请输入施工控制压实度"
          clearable
          @keyup.enter.native="handleQuery"
        />
      </el-form-item>
      <el-form-item>
        <el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery">搜索</el-button>
        <el-button icon="el-icon-refresh" size="mini" @click="resetQuery">重置</el-button>
      </el-form-item>
    </el-form>

    <el-row :gutter="10" class="mb8">
      <el-col :span="1.5">
        <el-button
          type="primary"
          plain
          icon="el-icon-plus"
          size="mini"
          @click="handleAdd"
          v-hasPermi="['report_wjjhl:wjjhlWdclphbsjBsInfo:add']"
        >新增</el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button
          type="success"
          plain
          icon="el-icon-edit"
          size="mini"
          :disabled="single"
          @click="handleUpdate"
          v-hasPermi="['report_wjjhl:wjjhlWdclphbsjBsInfo:edit']"
        >修改</el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button
          type="danger"
          plain
          icon="el-icon-delete"
          size="mini"
          :disabled="multiple"
          @click="handleDelete"
          v-hasPermi="['report_wjjhl:wjjhlWdclphbsjBsInfo:remove']"
        >删除</el-button>
      </el-col>
      <el-col :span="1.5">
        <el-button
          type="warning"
          plain
          icon="el-icon-download"
          size="mini"
          @click="handleExport"
          v-hasPermi="['report_wjjhl:wjjhlWdclphbsjBsInfo:export']"
        >导出</el-button>
      </el-col>
      <right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
    </el-row>

    <el-table v-loading="loading" :data="wjjhlWdclphbsjBsInfoList" @selection-change="handleSelectionChange">
      <el-table-column type="selection" width="55" align="center" />
      <el-table-column label="一份excel表格的唯一id(其他的excel主表，都应有此字段）" align="center" prop="excelId" v-if="true"/>
      <el-table-column label="共几页" align="center" prop="totalPage" />
      <el-table-column label="第几页" align="center" prop="page" />
      <el-table-column label="报告编号" align="center" prop="baogbh" />
      <el-table-column label="检测单位名称" align="center" prop="jiancdwmc" />
      <el-table-column label="工程部位/用途" align="center" prop="gongcbwyt" />
      <el-table-column label="样品名称" align="center" prop="yangpmc" />
      <el-table-column label="样品编号" align="center" prop="yangpbh" />
      <el-table-column label="样品数量" align="center" prop="yangpsl" />
      <el-table-column label="样品状态" align="center" prop="yangpzt" />
      <el-table-column label="样品时间" align="center" prop="yangpsj" />
      <el-table-column label="检测日期" align="center" prop="jiancrq" />
      <el-table-column label="试验条件温度" align="center" prop="shiytjwd" />
      <el-table-column label="试验条件湿度" align="center" prop="shiytjsd" />
      <el-table-column label="检测依据" align="center" prop="jiancyj" />
      <el-table-column label="判定依据" align="center" prop="pandyj" />
      <el-table-column label="主要仪器设备名称及编号" align="center" prop="zhuyyqsbmcjbh" />
      <el-table-column label="取样位置" align="center" prop="quywz" />
      <el-table-column label="委托/任务编号" align="center" prop="weitrwbh" />
      <el-table-column label="土样产地" align="center" prop="tuycd" />
      <el-table-column label="代表数量" align="center" prop="daibsl" />
      <el-table-column label="附加声明" align="center" prop="fujsm" />
      <el-table-column label="检测结论" align="center" prop="jiancjl" />
      <el-table-column label="施工委托单位" align="center" prop="shigwtdw" />
      <el-table-column label="工程名称" align="center" prop="gongcmc" />
      <el-table-column label="设备id逗号分隔" align="center" prop="shebIds" />
      <el-table-column label="标识该表是报告" align="center" prop="bgFlag" />
      <el-table-column label="检测依据ids" align="center" prop="jiancyjIds" />
      <el-table-column label="判定依据ids" align="center" prop="pandyjIds" />
      <el-table-column label="矿料名称1" align="center" prop="kuanglmc1" />
      <el-table-column label="矿料名称2" align="center" prop="kuanglmc2" />
      <el-table-column label="矿料名称3" align="center" prop="kuanglmc3" />
      <el-table-column label="矿料名称4" align="center" prop="kuanglmc4" />
      <el-table-column label="矿料名称5" align="center" prop="kuanglmc5" />
      <el-table-column label="矿料名称6" align="center" prop="kuanglmc6" />
      <el-table-column label="矿料名称7" align="center" prop="kuanglmc7" />
      <el-table-column label="矿料名称8" align="center" prop="kuanglmc8" />
      <el-table-column label="矿料比例1" align="center" prop="kuanglbl1" />
      <el-table-column label="矿料比例2" align="center" prop="kuanglbl2" />
      <el-table-column label="矿料比例3" align="center" prop="kuanglbl3" />
      <el-table-column label="矿料比例4" align="center" prop="kuanglbl4" />
      <el-table-column label="矿料比例5" align="center" prop="kuanglbl5" />
      <el-table-column label="矿料比例6" align="center" prop="kuanglbl6" />
      <el-table-column label="矿料比例7" align="center" prop="kuanglbl7" />
      <el-table-column label="矿料比例8" align="center" prop="kuanglbl8" />
      <el-table-column label="水泥剂量" align="center" prop="shuinjl" />
      <el-table-column label="最佳含水率" align="center" prop="zuijhsl" />
      <el-table-column label="最大干密度" align="center" prop="zuidgmd" />
      <el-table-column label="施工控制压实度" align="center" prop="shigkzysd" />
      <el-table-column label="操作" align="center" class-name="small-padding fixed-width">
        <template slot-scope="scope">
          <el-button
            size="mini"
            type="text"
            icon="el-icon-edit"
            @click="handleUpdate(scope.row)"
            v-hasPermi="['report_wjjhl:wjjhlWdclphbsjBsInfo:edit']"
          >修改</el-button>
          <el-button
            size="mini"
            type="text"
            icon="el-icon-delete"
            @click="handleDelete(scope.row)"
            v-hasPermi="['report_wjjhl:wjjhlWdclphbsjBsInfo:remove']"
          >删除</el-button>
        </template>
      </el-table-column>
    </el-table>

    <pagination
      v-show="total>0"
      :total="total"
      :page.sync="queryParams.pageNum"
      :limit.sync="queryParams.pageSize"
      @pagination="getList"
    />

    <!-- 添加或修改无机结合料稳定材料配合比设计试验检测报告对话框 -->
    <el-dialog :title="title" :visible.sync="open" width="500px" append-to-body>
      <el-form ref="form" :model="form" :rules="rules" label-width="80px">
        <el-form-item label="共几页" prop="totalPage">
          <el-input v-model="form.totalPage" placeholder="请输入共几页" />
        </el-form-item>
        <el-form-item label="第几页" prop="page">
          <el-input v-model="form.page" placeholder="请输入第几页" />
        </el-form-item>
        <el-form-item label="报告编号" prop="baogbh">
          <el-input v-model="form.baogbh" placeholder="请输入报告编号" />
        </el-form-item>
        <el-form-item label="检测单位名称" prop="jiancdwmc">
          <el-input v-model="form.jiancdwmc" placeholder="请输入检测单位名称" />
        </el-form-item>
        <el-form-item label="工程部位/用途" prop="gongcbwyt">
          <el-input v-model="form.gongcbwyt" placeholder="请输入工程部位/用途" />
        </el-form-item>
        <el-form-item label="样品名称" prop="yangpmc">
          <el-input v-model="form.yangpmc" placeholder="请输入样品名称" />
        </el-form-item>
        <el-form-item label="样品编号" prop="yangpbh">
          <el-input v-model="form.yangpbh" placeholder="请输入样品编号" />
        </el-form-item>
        <el-form-item label="样品数量" prop="yangpsl">
          <el-input v-model="form.yangpsl" placeholder="请输入样品数量" />
        </el-form-item>
        <el-form-item label="样品状态" prop="yangpzt">
          <el-input v-model="form.yangpzt" placeholder="请输入样品状态" />
        </el-form-item>
        <el-form-item label="样品时间" prop="yangpsj">
          <el-input v-model="form.yangpsj" placeholder="请输入样品时间" />
        </el-form-item>
        <el-form-item label="检测日期" prop="jiancrq">
          <el-input v-model="form.jiancrq" placeholder="请输入检测日期" />
        </el-form-item>
        <el-form-item label="试验条件温度" prop="shiytjwd">
          <el-input v-model="form.shiytjwd" placeholder="请输入试验条件温度" />
        </el-form-item>
        <el-form-item label="试验条件湿度" prop="shiytjsd">
          <el-input v-model="form.shiytjsd" placeholder="请输入试验条件湿度" />
        </el-form-item>
        <el-form-item label="检测依据" prop="jiancyj">
          <el-input v-model="form.jiancyj" placeholder="请输入检测依据" />
        </el-form-item>
        <el-form-item label="判定依据" prop="pandyj">
          <el-input v-model="form.pandyj" placeholder="请输入判定依据" />
        </el-form-item>
        <el-form-item label="主要仪器设备名称及编号" prop="zhuyyqsbmcjbh">
          <el-input v-model="form.zhuyyqsbmcjbh" placeholder="请输入主要仪器设备名称及编号" />
        </el-form-item>
        <el-form-item label="取样位置" prop="quywz">
          <el-input v-model="form.quywz" placeholder="请输入取样位置" />
        </el-form-item>
        <el-form-item label="委托/任务编号" prop="weitrwbh">
          <el-input v-model="form.weitrwbh" placeholder="请输入委托/任务编号" />
        </el-form-item>
        <el-form-item label="土样产地" prop="tuycd">
          <el-input v-model="form.tuycd" placeholder="请输入土样产地" />
        </el-form-item>
        <el-form-item label="代表数量" prop="daibsl">
          <el-input v-model="form.daibsl" placeholder="请输入代表数量" />
        </el-form-item>
        <el-form-item label="附加声明" prop="fujsm">
          <el-input v-model="form.fujsm" placeholder="请输入附加声明" />
        </el-form-item>
        <el-form-item label="检测结论" prop="jiancjl">
          <el-input v-model="form.jiancjl" placeholder="请输入检测结论" />
        </el-form-item>
        <el-form-item label="施工委托单位" prop="shigwtdw">
          <el-input v-model="form.shigwtdw" placeholder="请输入施工委托单位" />
        </el-form-item>
        <el-form-item label="工程名称" prop="gongcmc">
          <el-input v-model="form.gongcmc" placeholder="请输入工程名称" />
        </el-form-item>
        <el-form-item label="设备id逗号分隔" prop="shebIds">
          <el-input v-model="form.shebIds" type="textarea" placeholder="请输入内容" />
        </el-form-item>
        <el-form-item label="标识该表是报告" prop="bgFlag">
          <el-input v-model="form.bgFlag" placeholder="请输入标识该表是报告" />
        </el-form-item>
        <el-form-item label="检测依据ids" prop="jiancyjIds">
          <el-input v-model="form.jiancyjIds" type="textarea" placeholder="请输入内容" />
        </el-form-item>
        <el-form-item label="判定依据ids" prop="pandyjIds">
          <el-input v-model="form.pandyjIds" type="textarea" placeholder="请输入内容" />
        </el-form-item>
        <el-form-item label="矿料名称1" prop="kuanglmc1">
          <el-input v-model="form.kuanglmc1" placeholder="请输入矿料名称1" />
        </el-form-item>
        <el-form-item label="矿料名称2" prop="kuanglmc2">
          <el-input v-model="form.kuanglmc2" placeholder="请输入矿料名称2" />
        </el-form-item>
        <el-form-item label="矿料名称3" prop="kuanglmc3">
          <el-input v-model="form.kuanglmc3" placeholder="请输入矿料名称3" />
        </el-form-item>
        <el-form-item label="矿料名称4" prop="kuanglmc4">
          <el-input v-model="form.kuanglmc4" placeholder="请输入矿料名称4" />
        </el-form-item>
        <el-form-item label="矿料名称5" prop="kuanglmc5">
          <el-input v-model="form.kuanglmc5" placeholder="请输入矿料名称5" />
        </el-form-item>
        <el-form-item label="矿料名称6" prop="kuanglmc6">
          <el-input v-model="form.kuanglmc6" placeholder="请输入矿料名称6" />
        </el-form-item>
        <el-form-item label="矿料名称7" prop="kuanglmc7">
          <el-input v-model="form.kuanglmc7" placeholder="请输入矿料名称7" />
        </el-form-item>
        <el-form-item label="矿料名称8" prop="kuanglmc8">
          <el-input v-model="form.kuanglmc8" placeholder="请输入矿料名称8" />
        </el-form-item>
        <el-form-item label="矿料比例1" prop="kuanglbl1">
          <el-input v-model="form.kuanglbl1" placeholder="请输入矿料比例1" />
        </el-form-item>
        <el-form-item label="矿料比例2" prop="kuanglbl2">
          <el-input v-model="form.kuanglbl2" placeholder="请输入矿料比例2" />
        </el-form-item>
        <el-form-item label="矿料比例3" prop="kuanglbl3">
          <el-input v-model="form.kuanglbl3" placeholder="请输入矿料比例3" />
        </el-form-item>
        <el-form-item label="矿料比例4" prop="kuanglbl4">
          <el-input v-model="form.kuanglbl4" placeholder="请输入矿料比例4" />
        </el-form-item>
        <el-form-item label="矿料比例5" prop="kuanglbl5">
          <el-input v-model="form.kuanglbl5" placeholder="请输入矿料比例5" />
        </el-form-item>
        <el-form-item label="矿料比例6" prop="kuanglbl6">
          <el-input v-model="form.kuanglbl6" placeholder="请输入矿料比例6" />
        </el-form-item>
        <el-form-item label="矿料比例7" prop="kuanglbl7">
          <el-input v-model="form.kuanglbl7" placeholder="请输入矿料比例7" />
        </el-form-item>
        <el-form-item label="矿料比例8" prop="kuanglbl8">
          <el-input v-model="form.kuanglbl8" placeholder="请输入矿料比例8" />
        </el-form-item>
        <el-form-item label="水泥剂量" prop="shuinjl">
          <el-input v-model="form.shuinjl" placeholder="请输入水泥剂量" />
        </el-form-item>
        <el-form-item label="最佳含水率" prop="zuijhsl">
          <el-input v-model="form.zuijhsl" placeholder="请输入最佳含水率" />
        </el-form-item>
        <el-form-item label="最大干密度" prop="zuidgmd">
          <el-input v-model="form.zuidgmd" placeholder="请输入最大干密度" />
        </el-form-item>
        <el-form-item label="施工控制压实度" prop="shigkzysd">
          <el-input v-model="form.shigkzysd" placeholder="请输入施工控制压实度" />
        </el-form-item>
      </el-form>
      <div slot="footer" class="dialog-footer">
        <el-button :loading="buttonLoading" type="primary" @click="submitForm">确 定</el-button>
        <el-button @click="cancel">取 消</el-button>
      </div>
    </el-dialog>
  </div>
</template>

<script>
import { listWjjhlWdclphbsjBsInfo, getWjjhlWdclphbsjBsInfo, delWjjhlWdclphbsjBsInfo, addWjjhlWdclphbsjBsInfo, updateWjjhlWdclphbsjBsInfo } from "@/api/report_wjjhl/wjjhlWdclphbsjBsInfo";

export default {
  name: "WjjhlWdclphbsjBsInfo",
  data() {
    return {
      // 按钮loading
      buttonLoading: false,
      // 遮罩层
      loading: true,
      // 选中数组
      ids: [],
      // 非单个禁用
      single: true,
      // 非多个禁用
      multiple: true,
      // 显示搜索条件
      showSearch: true,
      // 总条数
      total: 0,
      // 无机结合料稳定材料配合比设计试验检测报告表格数据
      wjjhlWdclphbsjBsInfoList: [],
      // 弹出层标题
      title: "",
      // 是否显示弹出层
      open: false,
      // 查询参数
      queryParams: {
        pageNum: 1,
        pageSize: 10,
        totalPage: undefined,
        page: undefined,
        baogbh: undefined,
        jiancdwmc: undefined,
        gongcbwyt: undefined,
        yangpmc: undefined,
        yangpbh: undefined,
        yangpsl: undefined,
        yangpzt: undefined,
        yangpsj: undefined,
        jiancrq: undefined,
        shiytjwd: undefined,
        shiytjsd: undefined,
        jiancyj: undefined,
        pandyj: undefined,
        zhuyyqsbmcjbh: undefined,
        quywz: undefined,
        weitrwbh: undefined,
        tuycd: undefined,
        daibsl: undefined,
        fujsm: undefined,
        jiancjl: undefined,
        shigwtdw: undefined,
        gongcmc: undefined,
        shebIds: undefined,
        bgFlag: undefined,
        jiancyjIds: undefined,
        pandyjIds: undefined,
        kuanglmc1: undefined,
        kuanglmc2: undefined,
        kuanglmc3: undefined,
        kuanglmc4: undefined,
        kuanglmc5: undefined,
        kuanglmc6: undefined,
        kuanglmc7: undefined,
        kuanglmc8: undefined,
        kuanglbl1: undefined,
        kuanglbl2: undefined,
        kuanglbl3: undefined,
        kuanglbl4: undefined,
        kuanglbl5: undefined,
        kuanglbl6: undefined,
        kuanglbl7: undefined,
        kuanglbl8: undefined,
        shuinjl: undefined,
        zuijhsl: undefined,
        zuidgmd: undefined,
        shigkzysd: undefined
      },
      // 表单参数
      form: {},
      // 表单校验
      rules: {
      }
    };
  },
  created() {
    this.getList();
  },
  methods: {
    /** 查询无机结合料稳定材料配合比设计试验检测报告列表 */
    getList() {
      this.loading = true;
      listWjjhlWdclphbsjBsInfo(this.queryParams).then(response => {
        this.wjjhlWdclphbsjBsInfoList = response.rows;
        this.total = response.total;
        this.loading = false;
      });
    },
    // 取消按钮
    cancel() {
      this.open = false;
      this.reset();
    },
    // 表单重置
    reset() {
      this.form = {
        excelId: undefined,
        totalPage: undefined,
        page: undefined,
        baogbh: undefined,
        jiancdwmc: undefined,
        gongcbwyt: undefined,
        yangpmc: undefined,
        yangpbh: undefined,
        yangpsl: undefined,
        yangpzt: undefined,
        yangpsj: undefined,
        jiancrq: undefined,
        shiytjwd: undefined,
        shiytjsd: undefined,
        jiancyj: undefined,
        pandyj: undefined,
        zhuyyqsbmcjbh: undefined,
        quywz: undefined,
        weitrwbh: undefined,
        tuycd: undefined,
        daibsl: undefined,
        fujsm: undefined,
        delFlag: undefined,
        createBy: undefined,
        createTime: undefined,
        updateBy: undefined,
        updateTime: undefined,
        jiancjl: undefined,
        shigwtdw: undefined,
        gongcmc: undefined,
        shebIds: undefined,
        bgFlag: undefined,
        jiancyjIds: undefined,
        pandyjIds: undefined,
        kuanglmc1: undefined,
        kuanglmc2: undefined,
        kuanglmc3: undefined,
        kuanglmc4: undefined,
        kuanglmc5: undefined,
        kuanglmc6: undefined,
        kuanglmc7: undefined,
        kuanglmc8: undefined,
        kuanglbl1: undefined,
        kuanglbl2: undefined,
        kuanglbl3: undefined,
        kuanglbl4: undefined,
        kuanglbl5: undefined,
        kuanglbl6: undefined,
        kuanglbl7: undefined,
        kuanglbl8: undefined,
        shuinjl: undefined,
        zuijhsl: undefined,
        zuidgmd: undefined,
        shigkzysd: undefined
      };
      this.resetForm("form");
    },
    /** 搜索按钮操作 */
    handleQuery() {
      this.queryParams.pageNum = 1;
      this.getList();
    },
    /** 重置按钮操作 */
    resetQuery() {
      this.resetForm("queryForm");
      this.handleQuery();
    },
    // 多选框选中数据
    handleSelectionChange(selection) {
      this.ids = selection.map(item => item.excelId)
      this.single = selection.length!==1
      this.multiple = !selection.length
    },
    /** 新增按钮操作 */
    handleAdd() {
      this.reset();
      this.open = true;
      this.title = "添加无机结合料稳定材料配合比设计试验检测报告";
    },
    /** 修改按钮操作 */
    handleUpdate(row) {
      this.loading = true;
      this.reset();
      const excelId = row.excelId || this.ids
      getWjjhlWdclphbsjBsInfo(excelId).then(response => {
        this.loading = false;
        this.form = response.data;
        this.open = true;
        this.title = "修改无机结合料稳定材料配合比设计试验检测报告";
      });
    },
    /** 提交按钮 */
    submitForm() {
      this.$refs["form"].validate(valid => {
        if (valid) {
          this.buttonLoading = true;
          if (this.form.excelId != null) {
            updateWjjhlWdclphbsjBsInfo(this.form).then(response => {
              this.$modal.msgSuccess("修改成功");
              this.open = false;
              this.getList();
            }).finally(() => {
              this.buttonLoading = false;
            });
          } else {
            addWjjhlWdclphbsjBsInfo(this.form).then(response => {
              this.$modal.msgSuccess("新增成功");
              this.open = false;
              this.getList();
            }).finally(() => {
              this.buttonLoading = false;
            });
          }
        }
      });
    },
    /** 删除按钮操作 */
    handleDelete(row) {
      const excelIds = row.excelId || this.ids;
      this.$modal.confirm('是否确认删除无机结合料稳定材料配合比设计试验检测报告编号为"' + excelIds + '"的数据项？').then(() => {
        this.loading = true;
        return delWjjhlWdclphbsjBsInfo(excelIds);
      }).then(() => {
        this.loading = false;
        this.getList();
        this.$modal.msgSuccess("删除成功");
      }).catch(() => {
      }).finally(() => {
        this.loading = false;
      });
    },
    /** 导出按钮操作 */
    handleExport() {
      this.download('report_wjjhl/wjjhlWdclphbsjBsInfo/export', {
        ...this.queryParams
      }, `wjjhlWdclphbsjBsInfo_${new Date().getTime()}.xlsx`)
    }
  }
};
</script>
